
// MIT License
// 
// Copyright (c) 2009-2017 Luca Piccioni
// 
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
// 
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
// 
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
// 
// This file is automatically generated

#pragma warning disable 649, 1572, 1573

// ReSharper disable RedundantUsingDirective
using System;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Security;
using System.Text;

using Khronos;

// ReSharper disable CheckNamespace
// ReSharper disable InconsistentNaming
// ReSharper disable JoinDeclarationAndInitializer

namespace OpenGL
{
	public partial class Gl
	{
		/// <summary>
		/// [GL] glTexImage3DOES: Binding for glTexImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="internalformat">
		/// A <see cref="T:InternalFormat"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="depth">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="border">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="format">
		/// A <see cref="T:PixelFormat"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:PixelType"/>.
		/// </param>
		/// <param name="pixels">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void TexImage3DOES(TextureTarget target, int level, InternalFormat internalformat, int width, int height, int depth, int border, PixelFormat format, PixelType type, IntPtr pixels)
		{
			Debug.Assert(Delegates.pglTexImage3DOES != null, "pglTexImage3DOES not implemented");
			Delegates.pglTexImage3DOES((int)target, level, (int)internalformat, width, height, depth, border, (int)format, (int)type, pixels);
			LogCommand("glTexImage3DOES", null, target, level, internalformat, width, height, depth, border, format, type, pixels			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glTexImage3DOES: Binding for glTexImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="internalformat">
		/// A <see cref="T:InternalFormat"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="depth">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="border">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="format">
		/// A <see cref="T:PixelFormat"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:PixelType"/>.
		/// </param>
		/// <param name="pixels">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void TexImage3DOES(TextureTarget target, int level, InternalFormat internalformat, int width, int height, int depth, int border, PixelFormat format, PixelType type, object pixels)
		{
			GCHandle pin_pixels = GCHandle.Alloc(pixels, GCHandleType.Pinned);
			try {
				TexImage3DOES(target, level, internalformat, width, height, depth, border, format, type, pin_pixels.AddrOfPinnedObject());
			} finally {
				pin_pixels.Free();
			}
		}

		/// <summary>
		/// [GL] glTexSubImage3DOES: Binding for glTexSubImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="xoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="yoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="zoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="depth">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="format">
		/// A <see cref="T:PixelFormat"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:PixelType"/>.
		/// </param>
		/// <param name="pixels">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void TexSubImage3DOES(TextureTarget target, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, PixelFormat format, PixelType type, IntPtr pixels)
		{
			Debug.Assert(Delegates.pglTexSubImage3DOES != null, "pglTexSubImage3DOES not implemented");
			Delegates.pglTexSubImage3DOES((int)target, level, xoffset, yoffset, zoffset, width, height, depth, (int)format, (int)type, pixels);
			LogCommand("glTexSubImage3DOES", null, target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glTexSubImage3DOES: Binding for glTexSubImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="xoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="yoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="zoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="depth">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="format">
		/// A <see cref="T:PixelFormat"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:PixelType"/>.
		/// </param>
		/// <param name="pixels">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void TexSubImage3DOES(TextureTarget target, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, PixelFormat format, PixelType type, object pixels)
		{
			GCHandle pin_pixels = GCHandle.Alloc(pixels, GCHandleType.Pinned);
			try {
				TexSubImage3DOES(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pin_pixels.AddrOfPinnedObject());
			} finally {
				pin_pixels.Free();
			}
		}

		/// <summary>
		/// [GL] glCopyTexSubImage3DOES: Binding for glCopyTexSubImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="xoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="yoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="zoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="x">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="y">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void CopyTexSubImage3DOES(int target, int level, int xoffset, int yoffset, int zoffset, int x, int y, int width, int height)
		{
			Debug.Assert(Delegates.pglCopyTexSubImage3DOES != null, "pglCopyTexSubImage3DOES not implemented");
			Delegates.pglCopyTexSubImage3DOES(target, level, xoffset, yoffset, zoffset, x, y, width, height);
			LogCommand("glCopyTexSubImage3DOES", null, target, level, xoffset, yoffset, zoffset, x, y, width, height			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glCompressedTexImage3DOES: Binding for glCompressedTexImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="internalformat">
		/// A <see cref="T:InternalFormat"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="depth">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="border">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="imageSize">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="data">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void CompressedTexImage3DOES(TextureTarget target, int level, InternalFormat internalformat, int width, int height, int depth, int border, int imageSize, IntPtr data)
		{
			Debug.Assert(Delegates.pglCompressedTexImage3DOES != null, "pglCompressedTexImage3DOES not implemented");
			Delegates.pglCompressedTexImage3DOES((int)target, level, (int)internalformat, width, height, depth, border, imageSize, data);
			LogCommand("glCompressedTexImage3DOES", null, target, level, internalformat, width, height, depth, border, imageSize, data			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glCompressedTexImage3DOES: Binding for glCompressedTexImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="internalformat">
		/// A <see cref="T:InternalFormat"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="depth">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="border">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="imageSize">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="data">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void CompressedTexImage3DOES(TextureTarget target, int level, InternalFormat internalformat, int width, int height, int depth, int border, int imageSize, object data)
		{
			GCHandle pin_data = GCHandle.Alloc(data, GCHandleType.Pinned);
			try {
				CompressedTexImage3DOES(target, level, internalformat, width, height, depth, border, imageSize, pin_data.AddrOfPinnedObject());
			} finally {
				pin_data.Free();
			}
		}

		/// <summary>
		/// [GL] glCompressedTexSubImage3DOES: Binding for glCompressedTexSubImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="xoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="yoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="zoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="depth">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="format">
		/// A <see cref="T:PixelFormat"/>.
		/// </param>
		/// <param name="imageSize">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="data">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void CompressedTexSubImage3DOES(TextureTarget target, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, PixelFormat format, int imageSize, IntPtr data)
		{
			Debug.Assert(Delegates.pglCompressedTexSubImage3DOES != null, "pglCompressedTexSubImage3DOES not implemented");
			Delegates.pglCompressedTexSubImage3DOES((int)target, level, xoffset, yoffset, zoffset, width, height, depth, (int)format, imageSize, data);
			LogCommand("glCompressedTexSubImage3DOES", null, target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glCompressedTexSubImage3DOES: Binding for glCompressedTexSubImage3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="xoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="yoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="zoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="width">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="height">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="depth">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="format">
		/// A <see cref="T:PixelFormat"/>.
		/// </param>
		/// <param name="imageSize">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="data">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void CompressedTexSubImage3DOES(TextureTarget target, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, PixelFormat format, int imageSize, object data)
		{
			GCHandle pin_data = GCHandle.Alloc(data, GCHandleType.Pinned);
			try {
				CompressedTexSubImage3DOES(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, pin_data.AddrOfPinnedObject());
			} finally {
				pin_data.Free();
			}
		}

		/// <summary>
		/// [GL] glFramebufferTexture3DOES: Binding for glFramebufferTexture3DOES.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:FramebufferTarget"/>.
		/// </param>
		/// <param name="attachment">
		/// A <see cref="T:FramebufferAttachment"/>.
		/// </param>
		/// <param name="textarget">
		/// A <see cref="T:TextureTarget"/>.
		/// </param>
		/// <param name="texture">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="level">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="zoffset">
		/// A <see cref="T:int"/>.
		/// </param>
		[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
		public static void FramebufferTexture3DOES(FramebufferTarget target, FramebufferAttachment attachment, TextureTarget textarget, uint texture, int level, int zoffset)
		{
			Debug.Assert(Delegates.pglFramebufferTexture3DOES != null, "pglFramebufferTexture3DOES not implemented");
			Delegates.pglFramebufferTexture3DOES((int)target, (int)attachment, (int)textarget, texture, level, zoffset);
			LogCommand("glFramebufferTexture3DOES", null, target, attachment, textarget, texture, level, zoffset			);
			DebugCheckErrors(null);
		}

		internal static unsafe partial class Delegates
		{
			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glTexImage3DOES(int target, int level, int internalformat, int width, int height, int depth, int border, int format, int type, IntPtr pixels);

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[ThreadStatic]
			internal static glTexImage3DOES pglTexImage3DOES;

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glTexSubImage3DOES(int target, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, IntPtr pixels);

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[ThreadStatic]
			internal static glTexSubImage3DOES pglTexSubImage3DOES;

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glCopyTexSubImage3DOES(int target, int level, int xoffset, int yoffset, int zoffset, int x, int y, int width, int height);

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[ThreadStatic]
			internal static glCopyTexSubImage3DOES pglCopyTexSubImage3DOES;

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glCompressedTexImage3DOES(int target, int level, int internalformat, int width, int height, int depth, int border, int imageSize, IntPtr data);

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[ThreadStatic]
			internal static glCompressedTexImage3DOES pglCompressedTexImage3DOES;

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glCompressedTexSubImage3DOES(int target, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int imageSize, IntPtr data);

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[ThreadStatic]
			internal static glCompressedTexSubImage3DOES pglCompressedTexSubImage3DOES;

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glFramebufferTexture3DOES(int target, int attachment, int textarget, uint texture, int level, int zoffset);

			[RequiredByFeature("GL_OES_texture_3D", Api = "gles2")]
			[ThreadStatic]
			internal static glFramebufferTexture3DOES pglFramebufferTexture3DOES;

		}
	}

}
